package com.ruoyi.project.system.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.ruoyi.framework.aspectj.lang.annotation.Excel;
import com.ruoyi.framework.web.domain.BaseEntity;
import lombok.Data;
import java.math.BigDecimal;

@Data
public class SiyuRecharge extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 充值ID
     */
    private Integer id;

    /**
     * 用户ID
     */
    @Excel(name = "用户ID")
    private Long userId;

    /**
     * 充值类型
     */
    @Excel(name = "充值类型")
    private String rechargeType;

    /**
     * 充值前余额
     */
    @Excel(name = "充值前余额")
    private BigDecimal beforeBalance;

    /**
     * 充值额
     */
    @Excel(name = "充值额")
    private BigDecimal recharge;

    /**
     * 充值后余额
     */
    @Excel(name = "充值后余额")
    private BigDecimal afterBalance;

    /**
     * 支付单号
     */
    @Excel(name = "支付单号")
    private String outTradeNo;

    /**
     * 启用
     */
    @Excel(name = "启用")
    private String status;

    /**
     *支付额度
     */
    @TableField(exist = false)
    private BigDecimal totalFee;

    public SiyuRecharge() {
    }

    public SiyuRecharge(String outTradeNo) {
        this.outTradeNo = outTradeNo;
    }

    public SiyuRecharge(Long userId, BigDecimal beforeBalance, BigDecimal recharge, BigDecimal afterBalance) {
        this.userId = userId;
        this.beforeBalance = beforeBalance;
        this.recharge = recharge;
        this.afterBalance = afterBalance;
        this.rechargeType = "人工充值";
        this.status = "1";
    }


}
